﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using LotteryVote.Entity;
using LotteryVote.Utility;

namespace LotteryVote.Controls
{
    public partial class UserStateDropDownList : System.Web.UI.UserControl
    {
        public int SelectedIndex
        {
            get
            {
                return ddl_status.SelectedIndex;
            }
            set
            {
                ddl_status.SelectedIndex = value;
            }
        }
        public string SelectedValue
        {
            get
            {
                return ddl_status.SelectedValue;
            }
            set
            {
                ddl_status.SelectedValue = value;
            }
        }
        public UserState SelectedState
        {
            get
            {
                return EnumHelper.GetEnum<UserState>(SelectedValue);
            }
            set
            {
                ddl_status.SelectedValue = ((int)value).ToString();
            }
        }
        protected void Page_Load(object sender, EventArgs e)
        {

        }
    }
}